package com.code.generator.code.impl;

import com.code.config.DataSourceInfo;
import com.code.generator.context.velocity.VelocityGeneratorContext;

public class PersistenceGenerator extends AbstractVelocityGenerator {

    @Override
    protected String getTemplateName(VelocityGeneratorContext context) {
        return DataSourceInfo.DRIVER_CLASS.getValue() + "/Persistent.vm";
    }

    @Override
    protected String getPackageName(VelocityGeneratorContext context) {
        return context.get("packagePersistence").toString();
    }

    @Override
    protected String getFileName(VelocityGeneratorContext context) {
        return context.get("entity").toString() + ".java";
    }

}
